package com.icss.clothes.mapper;

import com.icss.clothes.entity.Address;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface AddressMapper {
    //从数据库中通过指定的用户编号查询得到收货地址信息
    @Select("select a.*,u.email,u.uphone from address a left outer join user u on a.user_id=u.user_id where u.user_id=#{user_id}")
    public List<Address> selectAllByUser_id(int user_id);
}
